load("//ReactNative:DEFS.bzl", "rn_android_library", "rn_android_prebuilt_aar", "rn_prebuilt_jar")

rn_android_prebuilt_aar(
    name = "fresco-react-native",
    aar = ":fresco-binary-aar",
    visibility = ["//ReactAndroid/..."],
)

remote_file(
    name = "fresco-binary-aar",
    sha1 = "c6ed3f696ed47dca3b20d4ffbd0600c94b9119b2",
    url = "mvn:com.facebook.fresco:fresco:aar:1.8.1",
)

android_prebuilt_aar(
    name = "fresco-drawee",
    aar = ":drawee-binary-aar",
    visibility = ["//ReactAndroid/..."],
)

remote_file(
    name = "drawee-binary-aar",
    sha1 = "6bc689901ddcac8f3df5ba4db1f8aabeb8e80107",
    url = "mvn:com.facebook.fresco:drawee:aar:1.8.1",
)

rn_android_library(
    name = "imagepipeline",
    exported_deps = [
        ":bolts",
        ":imagepipeline-base",
        ":imagepipeline-core",
    ],
    visibility = ["//ReactAndroid/..."],
)

rn_android_prebuilt_aar(
    name = "imagepipeline-base",
    aar = ":imagepipeline-base-aar",
    visibility = ["//ReactAndroid/..."],
)

remote_file(
    name = "imagepipeline-base-aar",
    sha1 = "42fd80c46a853850dfc0d71808b982fef401c841",
    url = "mvn:com.facebook.fresco:imagepipeline-base:aar:1.8.1",
)

rn_android_prebuilt_aar(
    name = "imagepipeline-core",
    aar = ":imagepipeline-aar",
    visibility = ["//ReactAndroid/..."],
)

remote_file(
    name = "imagepipeline-aar",
    sha1 = "06a2a4c3e1d9a7fb7d7f1ad14db63e2d32ef0b61",
    url = "mvn:com.facebook.fresco:imagepipeline:aar:1.8.1",
)

rn_prebuilt_jar(
    name = "bolts",
    binary_jar = ":download-bolts",
    visibility = ["//ReactAndroid/..."],
)

remote_file(
    name = "download-bolts",
    sha1 = "d85884acf6810a3bbbecb587f239005cbc846dc4",
    url = "mvn:com.parse.bolts:bolts-tasks:jar:1.4.0",
)

android_prebuilt_aar(
    name = "fbcore",
    aar = ":fbcore-aar",
    visibility = ["//ReactAndroid/..."],
)

remote_file(
    name = "fbcore-aar",
    sha1 = "99b7a83946e16f037149e4cd3abfd6840a09445d",
    url = "mvn:com.facebook.fresco:fbcore:aar:1.8.1",
)

android_prebuilt_aar(
    name = "imagepipeline-okhttp3",
    aar = ":imagepipeline-okhttp3-binary-aar",
    visibility = ["//ReactAndroid/..."],
)

remote_file(
    name = "imagepipeline-okhttp3-binary-aar",
    sha1 = "751f19412e1843b1c1e76eae46e388fb1deddbcc",
    url = "mvn:com.facebook.fresco:imagepipeline-okhttp3:aar:1.8.1",
)
